net: ena: limit refill Rx threshold to 256 to avoid latency issues
authorArthur Kiyanovski <akiyano@amazon.com>
Thu, 11 Oct 2018 08:26:23 +0000 (11:26 +0300)
committerSalvatore Bonaccorso <carnil@debian.org>
Sun, 30 Dec 2018 09:04:03 +0000 (09:04 +0000)
commit94dc16f58afcf1778113b4cdf898ed8b16e077fa
tree3c102bcd12f554b9cfa0d373acf3a3919e988de1
parent9fa96b5abe8e65c548d8dd6e16683b7a7b09e86c
net: ena: limit refill Rx threshold to 256 to avoid latency issues

Currently Rx refill is done when the number of required descriptors is
above 1/8 queue size. With a default of 1024 entries per queue the
threshold is 128 descriptors.
There is intention to increase the queue size to 8196 entries.
In this case threshold of 1024 descriptors is too large and can hurt
latency.
Add another limitation to Rx threshold to be at most 256 descriptors.

Signed-off-by: Arthur Kiyanovski <akiyano@amazon.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Gbp-Pq: Topic features/all/ena
Gbp-Pq: Name 0009-net-ena-limit-refill-Rx-threshold-to-256-to-avoid-la.patch
drivers/net/ethernet/amazon/ena/ena_netdev.c
drivers/net/ethernet/amazon/ena/ena_netdev.h